package com.knowvoyage.knowvoyageserver.service;

import com.knowvoyage.knowvoyageserver.pojo.dto.LearnDTO;
import com.knowvoyage.knowvoyageserver.pojo.entity.Learn;
import com.knowvoyage.knowvoyageserver.pojo.vo.Result;

import java.time.LocalDateTime;
import java.util.List;

public interface LearnService {
    Result<Boolean> insert(Learn learn);
    Result<Learn> selectById(Long learnId);
    Result<List<Learn>> selectByUserId(Long userId);
    Result<Boolean> delete(Long learnId);
    Result<Boolean> update(Learn learn);
    Result<List<Learn>> selectAll();

    Result<Boolean> recordLearning(LearnDTO learnDTO, String token);
    public List<Learn> selectWeekRecords(Long userId);
    public List<Learn> selectTodayRecords(Long userId);
    public List<Learn> selectByTimeRange(Long userId, LocalDateTime startTime, LocalDateTime endTime);
}
